<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <style>
        .father{
            width: 300px;
            height: 300px;
            background-color: aqua;
        }
        .son{
            width: 100px;
            height: 100px;
            background-color: blueviolet;
        }
    </style>
</head>
<body>
    <div id="app">
        <div class="father" @click.capture="getFather">
            <div class="son" @click.ctrl="getSon"></div>
        </div>

        <input type="text" v-model="code" @keydown.prevent.goput='put()'>
    </div>
   
    <script src="../js/vue.js"></script>
    <script>
       
        var vm = new Vue({
            el:'#app',
            data:{
                code:''
            },
            methods: {
                getFather(){
                    console.log('father')
                },
                getSon(){
                    console.log('son')
                },
                put(){
                    console.log(this.code)
                }
            },
        })
    </script>
</body>
</html>